1. Field of the Invention
The present invention relates to an image processing apparatus and an image processing system, and in particular to an image processing apparatus and an image processing system provided with a two-dimensional loading instruction in which a two-dimensional relative position is specified in an instruction code as immediate values.
2. Description of Related Art
Conventionally, an image processing apparatus has been proposed which reads data on a memory and writes the data for which predetermined operation processing has been performed to the memory. In the image processing apparatus, it is required to perform address calculation when certain data is specified and loaded, and there is a problem that the number of loadings increases as processing is complicated and the number of cycles required for the address calculation increases.
Therefore, an image processing apparatus is proposed in which, by giving an address on a memory at which data to be loaded is stored to an instruction field and loading the data by one instruction, the necessity of address calculation is eliminated. However, in the image processing apparatus, as the number of pixels to be stored in the memory is larger, the instruction field becomes longer. Furthermore, in the image processing apparatus, when multiple pixels are loaded at the same time, multiple long instruction fields are required, and therefore, there is a problem that the area of the instruction memory increases.
Furthermore, an image processing apparatus is proposed, for example, which transfers data in a predetermined rectangular area to a register in advance without specifying one or two pieces of data required for processing (see, for example, Japanese Patent Application Laid-Open Publication No. 2008-3708).
The proposed image processing apparatus is adapted to, when loading data from a memory, specify “loading starting address”, “increment width”, “data height” and “data interval” in an loading instruction and transfer data in a predetermined rectangular area to a register. However, all the data in the rectangular area which has been transferred to the register is not necessarily used for operation of image processing. Furthermore, the image processing apparatus requires the registers for storing the data in the predetermined rectangular area, and there is a problem that the necessary number of registers increases as the data in the rectangular area increases.